home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Compute! Gazette 1984 September
/
1984-09.d64
/
begin corner 1_6
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-09-20
|
1KB
|
53 lines
10 rem household inventory
20 for i=1 to 9:read r$(i):next
30 data living room,kitchen,bedrooms
40 data bathrooms,utility room,family room
50 data den,computer room,storage rooms
60 print "[147]"
70 print tab(12)"** inventory **"
80 print "choose:"
90 for i=1 to 9:print tab(4)i;r$(i):next
100 print tab(5)"0 whole house"
110 get a$:if a$<"0" or a$>"9" then 110
120 print "[147]"
130 a=val(a$)
140 tt=0
150 print tab(7)"inventory--";r$(a)""
160 restore:for i=1 to 9:read d$:next
170 read room,item$,c
180 if room=10 then 250
190 if a=0 then 210
200 if room<>a then 170
210 c$=str$(c)
220 print item$;tab(36-len(c$));c$
230 tt=tt+c
240 goto 170
250 t$=str$(tt)
260 print "total";tab(36-len(t$));t$
270 print "different room? (y/n)";
280 get a$:if a$="y" then 60
290 if a$="n" then 520
300 goto 280
310 rem inventory items
320 data 3,bed--bunk,200
330 data 3,bed--double,250
340 data 3,bed--king,725
350 data 8,computer,300
360 data 7,desk,130
370 data 6,dining table,325
380 data 5,dryer,350
390 data 1,loveseat,375
400 data 2,micro oven,450
410 data 1,piano,9800
420 data 8,printer,255
430 data 2,refrigerator,425
440 data 1,sofa,425
450 data 7,stereo,875
460 data 2,stove,525
470 data 8,television--13,225
480 data 6,television--19,475
490 data 7,typewriter,300
500 data 5,washing machine,560
510 data 10,zzz,0
520 end